package com.zh.elec.service.impl;

import java.util.List;

import com.zh.elec.dao.ProductDao;
import com.zh.elec.model.Product;
import com.zh.elec.service.ProductService;

/**
 * 商品表
 * @author scy
 *
 */
public class ProductServiceImpl implements ProductService {

	private ProductDao productDao;
	@Override
	public Object save(Product obj) {
		return productDao.save(obj);
	}

	@Override
	public Object update(Product obj) {
		return productDao.update(obj);
	}

	@Override
	public Object getObjById(Product obj) {
		return productDao.getObjById(obj);
	}

	@Override
	public Object del(Product obj) {
		return productDao.del(obj);
	}

	@Override
	public List<Product> find(String hql) {
		return productDao.findByHql(hql);
	}

	@Override
	public List<Product> findByName(String name, Object value) {
		return productDao.findByName(name, value);
	}
	@Override
	public List<Product> findAll() {
		return productDao.findAll();
	}
	public ProductDao getProductDao() {
		return productDao;
	}

	public void setProductDao(ProductDao productDao) {
		this.productDao = productDao;
	}
}
